import request from '@/utils/request'


export function fetchList() {
  return request({
    url: '/device/list',
    method: 'get'
  })
}


export function createDevice(data) {
  return request({
    url: '/device/create',
    method: 'post',
    data
  })
}

export function updateDevice(data) {
  return request({
    url: '/device/update',
    method: 'post',
    data
  })
}

export function deleteDevice(data) {
  return request({
    url: '/device/delete',
    method: 'post',
    data
  })
}


export function addInstance(data) {
  return request({
    url: '/device/ins/add',
    method: 'post',
    data
  })
}



export function getInsList(data) {
  return request({
    url: '/device/ins/list',
    method: 'post',
    data
  })
}
